<template>
	<view>
		<!-- 一条聊天记录  -->
		<view class="chat-item" v-for="(item,index) in msg" >
			<!-- 时间  -->
			<view class="time" v-if="item.isShowTime">2022.02.23</view>
			<!-- b - 对方的消息  -->
			<view class="content-wrapper-left">
				<!-- 头像 -->
				<image src="../../static/image/logo.png" class="avator avator-left"></image>
				<!-- 0 - 文字 -->
				<view class="chat-content-left" v-if="item.types === '0'">......</view>
				<!-- 1 - 图片 -->
				<view class="chat-image-left" v-if="item.types === '1'">......</view>
				<!-- 2 - 语音 -->
				<view class="chat-voice-left" v-if="item.types === '2'">......</view>
				<!-- 3 - 位置信息 -->
				<view class="chat-site-left" v-if="item.types === '3'">......</view>
			</view>
			<!--a - 自己的信息-->
			<view class="content-wrapper-right">
				<!-- 0 - 文字 -->
				<view class="chat-content-right" v-if="item.types === '0'">......</view>
				<!-- 1 - 图片 -->
				<view class="chat-image-right" v-if="item.types === '1'">......</view>
				<!-- 2 - 语音 -->
				<view class="chat-voice-right" v-if="item.types === '2'">......</view>
				<!-- 3 - 位置信息 -->
				<view class="chat-site chat-site-right">......</view>
				<!-- 头像 -->
				<image src="../../static/image/cat.png" class="avator avator-right"></image>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		name: "chatlist",
		data() {
			return {
				msg: [1, 2, 3]
			};
		}
	}
</script>

<style lang="scss">

</style>
